/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package GUI.SQL;

import GUI.DBF.UtamaDBF;
import java.awt.Desktop;
import java.io.IOException;
import java.net.URISyntaxException;
import java.net.URL;
import java.text.SimpleDateFormat;
import java.util.Calendar;
import java.util.logging.Level;
import java.util.logging.Logger;
import javax.swing.UIManager;
import javax.swing.UnsupportedLookAndFeelException;

/**
 *
 * @author rosi
 */
public class UtamaSQL extends javax.swing.JFrame {

    public UtamaSQL() {
        initComponents();
        SimpleDateFormat sdf = new SimpleDateFormat("dd MMMM yyyy");
        Calendar cal = Calendar.getInstance();
        labelTanggal.setText(sdf.format(cal.getTime()));
    }

    @SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        jLabel3 = new javax.swing.JLabel();
        jPanel1 = new javax.swing.JPanel();
        jLabel1 = new javax.swing.JLabel();
        jLabel2 = new javax.swing.JLabel();
        jLabel4 = new javax.swing.JLabel();
        jPanel2 = new javax.swing.JPanel();
        buttonGrafik = new javax.swing.JButton();
        buttonExit = new javax.swing.JButton();
        buttonPejualan = new javax.swing.JButton();
        buttonDBF = new javax.swing.JButton();
        jSeparator1 = new javax.swing.JSeparator();
        jSeparator2 = new javax.swing.JSeparator();
        jSeparator3 = new javax.swing.JSeparator();
        jSeparator4 = new javax.swing.JSeparator();
        jSeparator5 = new javax.swing.JSeparator();
        buttonFB = new javax.swing.JButton();
        buttonTwit = new javax.swing.JButton();
        buttonWeb = new javax.swing.JButton();
        buttonSettingDB = new javax.swing.JButton();
        labelTanggal = new javax.swing.JLabel();
        jLabel5 = new javax.swing.JLabel();
        jMenuBar1 = new javax.swing.JMenuBar();
        menuFile = new javax.swing.JMenu();
        menuExit = new javax.swing.JMenuItem();
        menuEdit = new javax.swing.JMenu();
        menuDBF = new javax.swing.JMenuItem();
        menuView = new javax.swing.JMenu();
        menuTingkatJual = new javax.swing.JMenuItem();
        menuGrafikPenjualan = new javax.swing.JMenuItem();
        menuSetting = new javax.swing.JMenu();
        menuSettingDB = new javax.swing.JMenuItem();

        setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
        setTitle("Home - SQL");

        jLabel3.setIcon(new javax.swing.ImageIcon(getClass().getResource("/gbr/logo.PNG"))); // NOI18N

        jPanel1.setBackground(new java.awt.Color(-1,true));

        jLabel1.setFont(new java.awt.Font("Dialog", 1, 24));
        jLabel1.setText("APLIKASI PENDATAAN PERGERAKAN BARANG");

        jLabel2.setFont(new java.awt.Font("Dialog", 1, 24));
        jLabel2.setText("PENERBIT PERCETAKAN KANISIUS");

        jLabel4.setFont(new java.awt.Font("Dialog", 1, 14));
        jLabel4.setText("Jalan Cempaka No. 9, Deresan, Yogyakarta");

        javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1);
        jPanel1.setLayout(jPanel1Layout);
        jPanel1Layout.setHorizontalGroup(
            jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel1Layout.createSequentialGroup()
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel1Layout.createSequentialGroup()
                        .addGap(23, 23, 23)
                        .addComponent(jLabel1))
                    .addGroup(jPanel1Layout.createSequentialGroup()
                        .addGap(91, 91, 91)
                        .addComponent(jLabel2))
                    .addGroup(jPanel1Layout.createSequentialGroup()
                        .addGap(147, 147, 147)
                        .addComponent(jLabel4)))
                .addContainerGap(34, Short.MAX_VALUE))
        );
        jPanel1Layout.setVerticalGroup(
            jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel1Layout.createSequentialGroup()
                .addComponent(jLabel1)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jLabel2)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jLabel4)
                .addContainerGap(53, Short.MAX_VALUE))
        );

        jPanel2.setBackground(new java.awt.Color(-1,true));
        jPanel2.setBorder(javax.swing.BorderFactory.createTitledBorder("Menu"));

        buttonGrafik.setIcon(new javax.swing.ImageIcon(getClass().getResource("/gbr/gr.PNG"))); // NOI18N
        buttonGrafik.setToolTipText("Lihat Grafik Penjualan");
        buttonGrafik.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        buttonGrafik.setVerticalTextPosition(javax.swing.SwingConstants.BOTTOM);
        buttonGrafik.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                buttonGrafikActionPerformed(evt);
            }
        });

        buttonExit.setIcon(new javax.swing.ImageIcon(getClass().getResource("/gbr/exit.PNG"))); // NOI18N
        buttonExit.setToolTipText("Exit");
        buttonExit.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                buttonExitActionPerformed(evt);
            }
        });

        buttonPejualan.setIcon(new javax.swing.ImageIcon(getClass().getResource("/gbr/kal.jpg"))); // NOI18N
        buttonPejualan.setToolTipText("Lihat Tingkat Penjualan");
        buttonPejualan.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                buttonPejualanActionPerformed(evt);
            }
        });

        buttonDBF.setIcon(new javax.swing.ImageIcon(getClass().getResource("/gbr/dbf.jpg"))); // NOI18N
        buttonDBF.setToolTipText("Ganti ke DBF");
        buttonDBF.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                buttonDBFActionPerformed(evt);
            }
        });

        jSeparator1.setBackground(new java.awt.Color(-12566464,true));
        jSeparator1.setOrientation(javax.swing.SwingConstants.VERTICAL);

        jSeparator2.setBackground(new java.awt.Color(-12566464,true));
        jSeparator2.setOrientation(javax.swing.SwingConstants.VERTICAL);

        jSeparator3.setBackground(new java.awt.Color(-12566464,true));
        jSeparator3.setOrientation(javax.swing.SwingConstants.VERTICAL);

        jSeparator4.setBackground(new java.awt.Color(-12566464,true));
        jSeparator4.setOrientation(javax.swing.SwingConstants.VERTICAL);

        jSeparator5.setBackground(new java.awt.Color(-12566464,true));
        jSeparator5.setOrientation(javax.swing.SwingConstants.VERTICAL);

        buttonFB.setIcon(new javax.swing.ImageIcon(getClass().getResource("/gbr/fb.jpg"))); // NOI18N
        buttonFB.setToolTipText("Facebook Kanisius");
        buttonFB.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                buttonFBActionPerformed(evt);
            }
        });

        buttonTwit.setIcon(new javax.swing.ImageIcon(getClass().getResource("/gbr/twit.jpg"))); // NOI18N
        buttonTwit.setToolTipText("Twitter Kanisius");
        buttonTwit.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                buttonTwitActionPerformed(evt);
            }
        });

        buttonWeb.setIcon(new javax.swing.ImageIcon(getClass().getResource("/gbr/icon kan.jpg"))); // NOI18N
        buttonWeb.setToolTipText("Web Kanisius Media");
        buttonWeb.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                buttonWebActionPerformed(evt);
            }
        });

        buttonSettingDB.setIcon(new javax.swing.ImageIcon(getClass().getResource("/gbr/set.jpg"))); // NOI18N
        buttonSettingDB.setToolTipText("Setting Database");
        buttonSettingDB.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                buttonSettingDBActionPerformed(evt);
            }
        });

        javax.swing.GroupLayout jPanel2Layout = new javax.swing.GroupLayout(jPanel2);
        jPanel2.setLayout(jPanel2Layout);
        jPanel2Layout.setHorizontalGroup(
            jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel2Layout.createSequentialGroup()
                .addContainerGap()
                .addComponent(buttonExit, javax.swing.GroupLayout.PREFERRED_SIZE, 49, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addGap(8, 8, 8)
                .addComponent(jSeparator1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addComponent(buttonGrafik, javax.swing.GroupLayout.PREFERRED_SIZE, 45, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addGap(20, 20, 20)
                .addComponent(buttonPejualan, javax.swing.GroupLayout.PREFERRED_SIZE, 44, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jSeparator3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addGap(8, 8, 8)
                .addComponent(buttonDBF, javax.swing.GroupLayout.PREFERRED_SIZE, 49, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jSeparator5, javax.swing.GroupLayout.PREFERRED_SIZE, 2, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addComponent(buttonSettingDB, javax.swing.GroupLayout.PREFERRED_SIZE, 44, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jSeparator2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 224, Short.MAX_VALUE)
                .addComponent(jSeparator4, javax.swing.GroupLayout.PREFERRED_SIZE, 12, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(buttonWeb, javax.swing.GroupLayout.PREFERRED_SIZE, 47, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addComponent(buttonFB, javax.swing.GroupLayout.PREFERRED_SIZE, 41, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(buttonTwit, javax.swing.GroupLayout.PREFERRED_SIZE, 39, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addContainerGap())
        );
        jPanel2Layout.setVerticalGroup(
            jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel2Layout.createSequentialGroup()
                .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                        .addComponent(jSeparator1, javax.swing.GroupLayout.DEFAULT_SIZE, 71, Short.MAX_VALUE)
                        .addComponent(jSeparator3)
                        .addComponent(jSeparator5)
                        .addComponent(jSeparator4, javax.swing.GroupLayout.Alignment.TRAILING)
                        .addGroup(jPanel2Layout.createSequentialGroup()
                            .addContainerGap()
                            .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                .addComponent(buttonGrafik, javax.swing.GroupLayout.PREFERRED_SIZE, 44, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addComponent(buttonPejualan, javax.swing.GroupLayout.PREFERRED_SIZE, 43, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addComponent(buttonDBF, javax.swing.GroupLayout.PREFERRED_SIZE, 42, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addComponent(buttonExit, javax.swing.GroupLayout.PREFERRED_SIZE, 45, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false)
                                    .addComponent(buttonFB, javax.swing.GroupLayout.Alignment.LEADING, 0, 0, Short.MAX_VALUE)
                                    .addComponent(buttonTwit, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.PREFERRED_SIZE, 39, Short.MAX_VALUE)))))
                    .addComponent(jSeparator2, javax.swing.GroupLayout.DEFAULT_SIZE, 71, Short.MAX_VALUE)
                    .addGroup(jPanel2Layout.createSequentialGroup()
                        .addContainerGap()
                        .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(buttonSettingDB, javax.swing.GroupLayout.PREFERRED_SIZE, 43, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(buttonWeb, javax.swing.GroupLayout.PREFERRED_SIZE, 47, javax.swing.GroupLayout.PREFERRED_SIZE))))
                .addContainerGap())
        );

        labelTanggal.setFont(new java.awt.Font("Tahoma", 1, 14));
        labelTanggal.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);

        jLabel5.setFont(new java.awt.Font("Tahoma", 1, 14));
        jLabel5.setText("Tanggal hari ini : ");

        menuFile.setText("File");

        menuExit.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_X, java.awt.event.InputEvent.ALT_MASK));
        menuExit.setText("Exit");
        menuExit.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                menuExitActionPerformed(evt);
            }
        });
        menuFile.add(menuExit);

        jMenuBar1.add(menuFile);

        menuEdit.setText("Edit");

        menuDBF.setText("Ganti DBF");
        menuDBF.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                menuDBFActionPerformed(evt);
            }
        });
        menuEdit.add(menuDBF);

        jMenuBar1.add(menuEdit);

        menuView.setText("View");

        menuTingkatJual.setText("Tingkat Penjualan");
        menuTingkatJual.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                menuTingkatJualActionPerformed(evt);
            }
        });
        menuView.add(menuTingkatJual);

        menuGrafikPenjualan.setText("Grafik Penjualan");
        menuGrafikPenjualan.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                menuGrafikPenjualanActionPerformed(evt);
            }
        });
        menuView.add(menuGrafikPenjualan);

        jMenuBar1.add(menuView);

        menuSetting.setText("Setting");

        menuSettingDB.setText("Setting DB");
        menuSettingDB.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                menuSettingDBActionPerformed(evt);
            }
        });
        menuSetting.add(menuSettingDB);

        jMenuBar1.add(menuSetting);

        setJMenuBar(jMenuBar1);

        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
        getContentPane().setLayout(layout);
        layout.setHorizontalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(layout.createSequentialGroup()
                        .addComponent(jLabel3, javax.swing.GroupLayout.PREFERRED_SIZE, 124, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jPanel1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                    .addGroup(layout.createSequentialGroup()
                        .addGap(10, 10, 10)
                        .addComponent(jPanel2, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                    .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()
                        .addGap(0, 426, Short.MAX_VALUE)
                        .addComponent(jLabel5)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(labelTanggal, javax.swing.GroupLayout.PREFERRED_SIZE, 187, javax.swing.GroupLayout.PREFERRED_SIZE)))
                .addContainerGap())
        );
        layout.setVerticalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jPanel1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(jLabel3, javax.swing.GroupLayout.PREFERRED_SIZE, 148, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(18, 18, 18)
                .addComponent(jPanel2, javax.swing.GroupLayout.PREFERRED_SIZE, 97, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                    .addComponent(jLabel5, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(labelTanggal, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                .addContainerGap(59, Short.MAX_VALUE))
        );

        pack();
    }// </editor-fold>//GEN-END:initComponents

    private void menuTingkatJualActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_menuTingkatJualActionPerformed
        // TODO add your handling code here:
        TingkatPenjualan grafik = new TingkatPenjualan();
        grafik.setVisible(true);
    }//GEN-LAST:event_menuTingkatJualActionPerformed

    private void menuDBFActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_menuDBFActionPerformed
        // TODO add your handling code here:
        UtamaDBF dbf = new UtamaDBF();
        dbf.setVisible(true);
        this.setVisible(false);
    }//GEN-LAST:event_menuDBFActionPerformed

    private void menuGrafikPenjualanActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_menuGrafikPenjualanActionPerformed
        // TODO add your handling code here:
        GrafikBulan bulan = new GrafikBulan();
        bulan.setVisible(true);
    }//GEN-LAST:event_menuGrafikPenjualanActionPerformed

    private void menuExitActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_menuExitActionPerformed
        // TODO add your handling code here:
        System.exit(0);
    }//GEN-LAST:event_menuExitActionPerformed

    private void menuSettingDBActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_menuSettingDBActionPerformed
        // TODO add your handling code here:
        SettingDB edit = new SettingDB(this, true);
        edit.setVisible(true);
    }//GEN-LAST:event_menuSettingDBActionPerformed

    private void buttonExitActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_buttonExitActionPerformed
        // TODO add your handling code here:
        System.exit(0);
    }//GEN-LAST:event_buttonExitActionPerformed

    private void buttonGrafikActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_buttonGrafikActionPerformed
        // TODO add your handling code here:
        GrafikBulan bulan = new GrafikBulan();
        bulan.setVisible(true);
    }//GEN-LAST:event_buttonGrafikActionPerformed

    private void buttonPejualanActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_buttonPejualanActionPerformed
        // TODO add your handling code here:
        TingkatPenjualan grafik = new TingkatPenjualan();
        grafik.setVisible(true);
    }//GEN-LAST:event_buttonPejualanActionPerformed

    private void buttonDBFActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_buttonDBFActionPerformed
        // TODO add your handling code here:
        UtamaDBF dbf = new UtamaDBF();
        dbf.setVisible(true);
    }//GEN-LAST:event_buttonDBFActionPerformed

    private void buttonSettingDBActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_buttonSettingDBActionPerformed
        // TODO add your handling code here:
        SettingDB edit = new SettingDB(this, true);
        edit.setVisible(true);
    }//GEN-LAST:event_buttonSettingDBActionPerformed

    private void buttonWebActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_buttonWebActionPerformed
        Desktop desk = Desktop.isDesktopSupported() ? Desktop.getDesktop() : null;
        if (desk != null && desk.isSupported(Desktop.Action.BROWSE)) {
            URL url = null;
            try {
                url = new URL("http://www.kanisiusmedia.com");
                desk.browse(url.toURI());
            } catch (URISyntaxException ex) {
                Logger.getLogger(UtamaSQL.class.getName()).log(Level.SEVERE, null, ex);
            } catch (IOException ex) {
                Logger.getLogger(UtamaSQL.class.getName()).log(Level.SEVERE, null, ex);
            }
        }
    }//GEN-LAST:event_buttonWebActionPerformed

    private void buttonFBActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_buttonFBActionPerformed
        // TODO add your handling code here:
        Desktop desk = Desktop.isDesktopSupported() ? Desktop.getDesktop() : null;
        if (desk != null && desk.isSupported(Desktop.Action.BROWSE)) {
            URL url = null;
            try {
                url = new URL("https://www.facebook.com/penerbitkanisius");
                desk.browse(url.toURI());
            } catch (URISyntaxException ex) {
                Logger.getLogger(UtamaSQL.class.getName()).log(Level.SEVERE, null, ex);
            } catch (IOException ex) {
                Logger.getLogger(UtamaSQL.class.getName()).log(Level.SEVERE, null, ex);
            }
        }
    }//GEN-LAST:event_buttonFBActionPerformed

    private void buttonTwitActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_buttonTwitActionPerformed
        // TODO add your handling code here:
        Desktop desk = Desktop.isDesktopSupported() ? Desktop.getDesktop() : null;
        if (desk != null && desk.isSupported(Desktop.Action.BROWSE)) {
            URL url = null;
            try {
                url = new URL("https://twitter.com/kanisiusmedia");
                desk.browse(url.toURI());
            } catch (URISyntaxException ex) {
                Logger.getLogger(UtamaSQL.class.getName()).log(Level.SEVERE, null, ex);
            } catch (IOException ex) {
                Logger.getLogger(UtamaSQL.class.getName()).log(Level.SEVERE, null, ex);
            }
        }
    }//GEN-LAST:event_buttonTwitActionPerformed

    /**
     * @param args the command line arguments
     */
    public static void main(String args[]) {
        try {
            UIManager.setLookAndFeel("com.sun.java.swing.plaf.windows.WindowsLookAndFeel");
        } catch (ClassNotFoundException ex) {
            Logger.getLogger(UtamaSQL.class.getName()).log(Level.SEVERE, null, ex);
        } catch (InstantiationException ex) {
            Logger.getLogger(UtamaSQL.class.getName()).log(Level.SEVERE, null, ex);
        } catch (IllegalAccessException ex) {
            Logger.getLogger(UtamaSQL.class.getName()).log(Level.SEVERE, null, ex);
        } catch (UnsupportedLookAndFeelException ex) {
            Logger.getLogger(UtamaSQL.class.getName()).log(Level.SEVERE, null, ex);
        }
        java.awt.EventQueue.invokeLater(new Runnable() {

            @Override
            public void run() {
                new UtamaSQL().setVisible(true);
            }
        });
    }
    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JButton buttonDBF;
    private javax.swing.JButton buttonExit;
    private javax.swing.JButton buttonFB;
    private javax.swing.JButton buttonGrafik;
    private javax.swing.JButton buttonPejualan;
    private javax.swing.JButton buttonSettingDB;
    private javax.swing.JButton buttonTwit;
    private javax.swing.JButton buttonWeb;
    private javax.swing.JLabel jLabel1;
    private javax.swing.JLabel jLabel2;
    private javax.swing.JLabel jLabel3;
    private javax.swing.JLabel jLabel4;
    private javax.swing.JLabel jLabel5;
    private javax.swing.JMenuBar jMenuBar1;
    private javax.swing.JPanel jPanel1;
    private javax.swing.JPanel jPanel2;
    private javax.swing.JSeparator jSeparator1;
    private javax.swing.JSeparator jSeparator2;
    private javax.swing.JSeparator jSeparator3;
    private javax.swing.JSeparator jSeparator4;
    private javax.swing.JSeparator jSeparator5;
    private javax.swing.JLabel labelTanggal;
    private javax.swing.JMenuItem menuDBF;
    private javax.swing.JMenu menuEdit;
    private javax.swing.JMenuItem menuExit;
    private javax.swing.JMenu menuFile;
    private javax.swing.JMenuItem menuGrafikPenjualan;
    private javax.swing.JMenu menuSetting;
    private javax.swing.JMenuItem menuSettingDB;
    private javax.swing.JMenuItem menuTingkatJual;
    private javax.swing.JMenu menuView;
    // End of variables declaration//GEN-END:variables
}
